const telphoneReg = /^(((13[0-9]{1})|(15[0-9]{1})|(18[0-9]{1}))+\d{8})$/

export const telphoneValid = (value) => {
  if (!telphoneReg.test(value)) {
    return false
  }

  return true
}

const emailReg = /^[a-z0-9]+([._\\-]*[a-z0-9])*@([a-z0-9]+[-a-z0-9]*[a-z0-9]+.){1,63}[a-z0-9]+$/

export const emailValid = (value) => {
  if (!emailReg.test(value)) {
    return false
  }

  return true
}
